home *** CD-ROM | disk | FTP | other *** search
/ BBS in a Box 10 / BBS In A Box Volume X (AMUG) (January 1994).bin / Files / Prog / U-Z / VideoToolBox.cpt / VideoToolboxSources / Zoom.c < prev   
MacBinary  |  1993-02-27  |  2.1 KB  |  [TEXT/KAHL]

open in: MacOS 8.1     |     Win98     |     DOS

browse contents    |     view JSON data     |     view as text


This file was processed as: MacBinary (archive/macBinary).

ConfidenceProgramDetectionMatch TypeSupport
66% dexvert Compact Compressed (Unix) (archive/compact) ext Supported
10% dexvert MacBinary (archive/macBinary) fallback Supported
10% dexvert Jesper Olsen Module (music/jesperOlsen) magic Supported
1% dexvert Text File (text/txt) fallback Supported
100% file MacBinary II, inited, Sat Feb 27 16:24:26 1993, modified Sat Feb 27 16:24:26 1993, creator Think C, type ASCII, 1581 bytes "Zoom.c" , at 0x6ad 382 bytes resource default (weak)
99% file data default
49% TrID Macintosh plain text (MacBinary) default
33% TrID TTComp archive compressed (bin-4K) default (weak)
16% TrID MacBinary 2 default (weak)
100% siegfried fmt/1762 MacBinary (II) default
100% lsar MacBinary default


id metadata
keyvalue
macFileType[TEXT]
macFileCreator[KAHL]



hex view
+--------+-------------------------+-------------------------+--------+--------+
|00000000| 00 06 5a 6f 6f 6d 2e 63 | 00 00 00 00 00 00 00 00 |..Zoom.c|........|
|00000010| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000020| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000030| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000040| 00 54 45 58 54 4b 41 48 | 4c 01 00 00 00 00 00 00 |.TEXTKAH|L.......|
|00000050| 00 00 00 00 00 06 2d 00 | 00 01 7e a7 b5 8c 8a a7 |......-.|..~.....|
|00000060| b5 8c 8a 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000070| 00 00 00 00 00 00 00 00 | 00 00 81 81 f9 9c 00 00 |........|........|
|00000080| 2f 2a 0d 5a 6f 6f 6d 2e | 63 20 0d 31 30 2f 31 37 |/*.Zoom.|c .10/17|
|00000090| 2f 39 30 09 64 67 70 09 | 74 72 61 6e 73 6c 61 74 |/90.dgp.|translat|
|000000a0| 65 64 20 66 72 6f 6d 20 | 70 61 73 63 61 6c 20 44 |ed from |pascal D|
|000000b0| 6f 57 5a 6f 6f 6d 2e 70 | 20 69 6e 20 49 6e 73 69 |oWZoom.p| in Insi|
|000000c0| 64 65 20 4d 61 63 20 56 | 49 2e 0d 31 30 2f 31 38 |de Mac V|I..10/18|
|000000d0| 2f 39 30 20 64 67 70 09 | 72 65 6d 6f 76 65 64 20 |/90 dgp.|removed |
|000000e0| 70 61 72 74 20 6f 66 20 | 74 68 65 20 63 6f 64 65 |part of |the code|
|000000f0| 20 74 6f 20 6d 61 6b 65 | 20 47 65 74 57 69 6e 64 | to make| GetWind|
|00000100| 6f 77 44 65 76 69 63 65 | 28 29 2c 20 77 68 69 63 |owDevice|(), whic|
|00000110| 68 20 49 20 70 75 74 0d | 09 09 09 09 69 6e 20 47 |h I put.|....in G|
|00000120| 65 74 53 63 72 65 65 6e | 44 65 76 69 63 65 2e 63 |etScreen|Device.c|
|00000130| 0d 38 2f 32 34 2f 39 31 | 09 64 67 70 09 09 4d 61 |.8/24/91|.dgp..Ma|
|00000140| 64 65 20 63 6f 6d 70 61 | 74 69 62 6c 65 20 77 69 |de compa|tible wi|
|00000150| 74 68 20 54 48 49 4e 4b | 20 43 20 35 2e 30 2e 0d |th THINK| C 5.0..|
|00000160| 31 32 2f 32 37 2f 39 31 | 20 64 67 70 09 45 78 74 |12/27/91| dgp.Ext|
|00000170| 72 61 63 74 65 64 20 63 | 6f 64 65 20 74 6f 20 63 |racted c|ode to c|
|00000180| 72 65 61 74 65 20 54 69 | 74 6c 65 42 61 72 48 65 |reate Ti|tleBarHe|
|00000190| 69 67 68 74 2e 63 0d 33 | 2f 32 36 2f 39 32 09 64 |ight.c.3|/26/92.d|
|000001a0| 67 70 09 09 52 65 70 6c | 61 63 65 64 20 75 73 65 |gp..Repl|aced use|
|000001b0| 20 6f 66 20 53 79 73 45 | 6e 76 69 72 6f 6e 73 28 | of SysE|nvirons(|
|000001c0| 29 20 62 79 20 61 20 63 | 61 6c 6c 20 74 6f 20 51 |) by a c|all to Q|
|000001d0| 44 38 45 78 69 73 74 73 | 28 29 2e 0d 2a 2f 0d 23 |D8Exists|()..*/.#|
|000001e0| 69 6e 63 6c 75 64 65 20 | 22 56 69 64 65 6f 54 6f |include |"VideoTo|
|000001f0| 6f 6c 62 6f 78 2e 68 22 | 0d 23 69 66 20 54 48 49 |olbox.h"|.#if THI|
|00000200| 4e 4b 5f 43 0d 09 23 69 | 6e 63 6c 75 64 65 20 3c |NK_C..#i|nclude <|
|00000210| 4c 6f 4d 65 6d 2e 68 3e | 0d 23 65 6c 73 65 0d 09 |LoMem.h>|.#else..|
|00000220| 73 68 6f 72 74 20 4d 42 | 61 72 48 65 69 67 68 74 |short MB|arHeight|
|00000230| 20 3a 20 30 78 42 41 41 | 3b 0d 23 65 6e 64 69 66 | : 0xBAA|;.#endif|
|00000240| 0d 0d 76 6f 69 64 20 5a | 6f 6f 6d 28 57 69 6e 64 |..void Z|oom(Wind|
|00000250| 6f 77 50 74 72 20 74 68 | 65 57 69 6e 64 6f 77 2c |owPtr th|eWindow,|
|00000260| 20 69 6e 74 20 7a 6f 6f | 6d 44 69 72 29 0d 7b 0d | int zoo|mDir).{.|
|00000270| 09 52 65 63 74 20 72 3b | 0d 09 47 44 48 61 6e 64 |.Rect r;|..GDHand|
|00000280| 6c 65 20 64 6f 6d 69 6e | 61 6e 74 47 44 65 76 69 |le domin|antGDevi|
|00000290| 63 65 3b 0d 09 69 6e 74 | 20 68 65 61 64 52 6f 6f |ce;..int| headRoo|
|000002a0| 6d 3b 0d 09 47 72 61 66 | 50 74 72 20 73 61 76 65 |m;..Graf|Ptr save|
|000002b0| 50 6f 72 74 3b 0d 09 65 | 78 74 65 72 6e 20 45 76 |Port;..e|xtern Ev|
|000002c0| 65 6e 74 52 65 63 6f 72 | 64 20 74 68 65 45 76 65 |entRecor|d theEve|
|000002d0| 6e 74 3b 09 2f 2a 20 67 | 6c 6f 62 61 6c 20 66 72 |nt;./* g|lobal fr|
|000002e0| 6f 6d 20 6d 61 69 6e 20 | 70 72 6f 67 72 61 6d 20 |om main |program |
|000002f0| 2a 2f 0d 09 0d 09 69 66 | 28 54 72 61 63 6b 42 6f |*/....if|(TrackBo|
|00000300| 78 28 74 68 65 57 69 6e | 64 6f 77 2c 74 68 65 45 |x(theWin|dow,theE|
|00000310| 76 65 6e 74 2e 77 68 65 | 72 65 2c 7a 6f 6f 6d 44 |vent.whe|re,zoomD|
|00000320| 69 72 29 29 7b 0d 09 09 | 47 65 74 50 6f 72 74 28 |ir)){...|GetPort(|
|00000330| 26 73 61 76 65 50 6f 72 | 74 29 3b 0d 09 09 53 65 |&savePor|t);...Se|
|00000340| 74 50 6f 72 74 28 74 68 | 65 57 69 6e 64 6f 77 29 |tPort(th|eWindow)|
|00000350| 3b 0d 09 09 45 72 61 73 | 65 52 65 63 74 28 26 74 |;...Eras|eRect(&t|
|00000360| 68 65 57 69 6e 64 6f 77 | 2d 3e 70 6f 72 74 52 65 |heWindow|->portRe|
|00000370| 63 74 29 3b 09 09 2f 2a | 72 65 63 6f 6d 6d 65 6e |ct);../*|recommen|
|00000380| 64 65 64 20 66 6f 72 20 | 63 6f 73 6d 65 74 69 63 |ded for |cosmetic|
|00000390| 20 72 65 61 73 6f 6e 73 | 2a 2f 0d 09 09 2f 2a 20 | reasons|*/.../* |
|000003a0| 49 66 20 74 68 65 72 65 | 20 69 73 20 74 68 65 20 |If there| is the |
|000003b0| 70 6f 73 73 69 62 69 6c | 69 74 79 20 6f 66 20 6d |possibil|ity of m|
|000003c0| 75 6c 74 69 70 6c 65 20 | 67 44 65 76 69 63 65 73 |ultiple |gDevices|
|000003d0| 2c 20 74 68 65 6e 20 77 | 65 20 2a 2f 0d 09 09 2f |, then w|e */.../|
|000003e0| 2a 20 6d 75 73 74 20 63 | 68 65 63 6b 20 74 68 65 |* must c|heck the|
|000003f0| 6d 20 74 6f 20 6d 61 6b | 65 20 73 75 72 65 20 77 |m to mak|e sure w|
|00000400| 65 20 61 72 65 20 7a 6f | 6f 6d 69 6e 67 20 6f 6e |e are zo|oming on|
|00000410| 74 6f 20 74 68 65 20 72 | 69 67 68 74 20 2a 2f 0d |to the r|ight */.|
|00000420| 09 09 2f 2a 20 64 69 73 | 70 6c 61 79 20 64 65 76 |../* dis|play dev|
|00000430| 69 63 65 20 77 68 65 6e | 20 7a 6f 6f 6d 69 6e 67 |ice when| zooming|
|00000440| 20 6f 75 74 2e 20 2a 2f | 0d 09 09 69 66 28 7a 6f | out. */|...if(zo|
|00000450| 6f 6d 44 69 72 3d 3d 69 | 6e 5a 6f 6f 6d 4f 75 74 |omDir==i|nZoomOut|
|00000460| 20 26 26 20 51 44 38 45 | 78 69 73 74 73 28 29 29 | && QD8E|xists())|
|00000470| 7b 0d 09 09 09 68 65 61 | 64 52 6f 6f 6d 3d 54 69 |{....hea|dRoom=Ti|
|00000480| 74 6c 65 42 61 72 48 65 | 69 67 68 74 28 74 68 65 |tleBarHe|ight(the|
|00000490| 57 69 6e 64 6f 77 29 3b | 0d 09 09 09 2f 2a 20 57 |Window);|..../* W|
|000004a0| 65 20 6d 75 73 74 20 63 | 72 65 61 74 65 20 61 20 |e must c|reate a |
|000004b0| 7a 6f 6f 6d 20 72 65 63 | 74 61 6e 67 6c 65 20 6d |zoom rec|tangle m|
|000004c0| 61 6e 75 61 6c 6c 79 20 | 69 6e 20 74 68 69 73 20 |anually |in this |
|000004d0| 63 61 73 65 2e 20 2a 2f | 0d 09 09 09 2f 2a 20 41 |case. */|..../* A|
|000004e0| 63 63 6f 75 6e 74 20 66 | 6f 72 20 6d 65 6e 75 20 |ccount f|or menu |
|000004f0| 62 61 72 20 68 65 69 67 | 68 74 20 61 73 20 77 65 |bar heig|ht as we|
|00000500| 6c 6c 2c 20 69 66 20 6f | 6e 20 6d 61 69 6e 20 64 |ll, if o|n main d|
|00000510| 65 76 69 63 65 20 2a 2f | 0d 09 09 09 64 6f 6d 69 |evice */|....domi|
|00000520| 6e 61 6e 74 47 44 65 76 | 69 63 65 3d 47 65 74 57 |nantGDev|ice=GetW|
|00000530| 69 6e 64 6f 77 44 65 76 | 69 63 65 28 74 68 65 57 |indowDev|ice(theW|
|00000540| 69 6e 64 6f 77 29 3b 0d | 09 09 09 69 66 28 64 6f |indow);.|...if(do|
|00000550| 6d 69 6e 61 6e 74 47 44 | 65 76 69 63 65 3d 3d 47 |minantGD|evice==G|
|00000560| 65 74 4d 61 69 6e 44 65 | 76 69 63 65 28 29 29 20 |etMainDe|vice()) |
|00000570| 68 65 61 64 52 6f 6f 6d | 20 2b 3d 20 4d 42 61 72 |headRoom| += MBar|
|00000580| 48 65 69 67 68 74 3b 0d | 09 09 09 72 3d 28 2a 64 |Height;.|...r=(*d|
|00000590| 6f 6d 69 6e 61 6e 74 47 | 44 65 76 69 63 65 29 2d |ominantG|Device)-|
|000005a0| 3e 67 64 52 65 63 74 3b | 0d 09 09 09 53 65 74 52 |>gdRect;|....SetR|
|000005b0| 65 63 74 28 26 72 2c 72 | 2e 6c 65 66 74 2b 33 2c |ect(&r,r|.left+3,|
|000005c0| 72 2e 74 6f 70 2b 68 65 | 61 64 52 6f 6f 6d 2b 33 |r.top+he|adRoom+3|
|000005d0| 2c 72 2e 72 69 67 68 74 | 2d 33 2c 72 2e 62 6f 74 |,r.right|-3,r.bot|
|000005e0| 74 6f 6d 2d 33 29 3b 0d | 09 09 09 2f 2a 20 53 65 |tom-3);.|.../* Se|
|000005f0| 74 20 75 70 20 74 68 65 | 20 57 53 74 61 74 65 44 |t up the| WStateD|
|00000600| 61 74 61 20 72 65 63 6f | 72 64 20 66 6f 72 20 74 |ata reco|rd for t|
|00000610| 68 69 73 20 77 69 6e 64 | 6f 77 2e 20 2a 2f 0d 09 |his wind|ow. */..|
|00000620| 09 09 28 2a 28 28 57 53 | 74 61 74 65 44 61 74 61 |..(*((WS|tateData|
|00000630| 20 2a 2a 29 28 28 57 69 | 6e 64 6f 77 50 65 65 6b | **)((Wi|ndowPeek|
|00000640| 29 74 68 65 57 69 6e 64 | 6f 77 29 2d 3e 64 61 74 |)theWind|ow)->dat|
|00000650| 61 48 61 6e 64 6c 65 29 | 29 2d 3e 73 74 64 53 74 |aHandle)|)->stdSt|
|00000660| 61 74 65 20 3d 20 72 3b | 0d 09 09 7d 0d 09 09 5a |ate = r;|...}...Z|
|00000670| 6f 6f 6d 57 69 6e 64 6f | 77 28 74 68 65 57 69 6e |oomWindo|w(theWin|
|00000680| 64 6f 77 2c 7a 6f 6f 6d | 44 69 72 2c 54 52 55 45 |dow,zoom|Dir,TRUE|
|00000690| 29 3b 0d 09 09 53 65 74 | 50 6f 72 74 28 73 61 76 |);...Set|Port(sav|
|000006a0| 65 50 6f 72 74 29 3b 0d | 09 7d 0d 7d 0d 00 00 00 |ePort);.|.}.}....|
|000006b0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000006c0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000006d0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000006e0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000006f0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000700| 00 00 01 00 00 00 01 4c | 00 00 00 4c 00 00 00 32 |.......L|...L...2|
|00000710| 66 72 6f 6d 20 6d 61 69 | 6e 20 70 72 6f 67 72 61 |from mai|n progra|
|00000720| 6d 20 2a 2f 0d 09 0d 09 | 69 66 28 54 72 61 63 6b |m */....|if(Track|
|00000730| 06 5a 6f 6f 6d 2e 63 5a | 02 00 00 00 54 45 58 54 |.Zoom.cZ|....TEXT|
|00000740| 4b 41 48 4c 00 00 00 00 | 00 00 00 00 00 00 32 2b |KAHL....|......2+|
|00000750| 00 00 54 45 58 54 4b 41 | 48 4c 00 00 00 00 00 00 |..TEXTKA|HL......|
|00000760| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000770| 00 00 a7 e5 d5 d9 00 00 | 00 00 00 00 01 7e 64 6f |........|.....~do|
|00000780| 77 29 3b 0d 09 09 45 72 | 61 73 65 52 65 63 74 28 |w);...Er|aseRect(|
|00000790| 26 74 68 65 57 69 6e 64 | 6f 77 2d 3e 70 6f 72 74 |&theWind|ow->port|
|000007a0| 52 65 63 74 29 3b 09 09 | 2f 2a 72 65 63 6f 6d 6d |Rect);..|/*recomm|
|000007b0| 65 6e 64 65 64 20 66 6f | 72 20 63 6f 73 6d 65 74 |ended fo|r cosmet|
|000007c0| 69 63 20 72 65 61 73 6f | 6e 73 2a 2f 0d 09 09 2f |ic reaso|ns*/.../|
|000007d0| 2a 20 49 66 20 74 68 65 | 72 65 20 69 73 20 74 68 |* If the|re is th|
|000007e0| 65 20 70 6f 73 73 69 62 | 69 6c 69 74 79 20 6f 66 |e possib|ility of|
|000007f0| 20 6d 75 6c 74 69 70 6c | 65 20 67 44 65 76 69 63 | multipl|e gDevic|
|00000800| 00 00 00 48 00 09 4d 6f | 6e 61 63 6f 00 00 04 44 |...H..Mo|naco...D|
|00000810| 44 44 44 40 00 44 44 44 | 44 40 00 55 55 55 55 00 |DDD@.DDD|D@.UUUU.|
|00000820| 00 06 66 66 66 00 00 06 | 00 04 00 2a 00 03 01 dd |..fff...|...*....|
|00000830| 02 7d 01 7c 00 00 01 dd | 02 3d a4 aa a1 ea 00 00 |.}.|....|.=......|
|00000840| 01 74 00 00 01 74 00 00 | 00 b4 01 00 00 00 01 00 |.t...t..|........|
|00000850| 00 00 01 4c 00 00 00 4c | 00 00 00 32 00 5d 6f a8 |...L...L|...2.]o.|
|00000860| 10 88 00 00 00 1c 00 32 | 00 00 4d 50 53 52 00 00 |.......2|..MPSR..|
|00000870| 00 0a 03 ed ff ff 00 00 | 00 00 00 5f 8b 70 00 00 |........|..._.p..|
+--------+-------------------------+-------------------------+--------+--------+